home *** CD-ROM | disk | FTP | other *** search
Text File | 1989-06-26 | 2.0 KB | 76 lines | [TEXT/GEOL] |
- Item 8212151 15-June-89 06:06
-
- From: D1665 Data Translation, W Feninger, PRT
-
- To: MACDTS Macintosh Developer Technical Supt.
-
- cc: MACAPP.TECH$ MACAPP Tech
-
- Sub: WDEF's in MacApp
-
-
- To : MacDTS
- MacApp.Tech$
-
- From : Tom McCarthy
- Data Translation, Inc.
-
- Subject : Custom WDEF's and MacApp
-
- Date : 6/15/89
-
-
- I have a non MacApp application that implements a custom WDEF window. I
- also have a MacApp (v2.0) application which stores its views in a 'view'
- resource and creates the window and views by calling NewTemplateWindow.
-
-
- The 'view' resource does not appear to provide for custom WDEF's. What methods
- should I override to:
-
- A. Create a window with my own WDEF and
-
- B. load the windows from the 'view' resource.
-
- I modified the "Nothing" sample program to use the new WDEF resource and load
- a single view from a 'view' resource. But, I have not had any success
- creating a scrolling view. This is what I have so far:
-
- {----------------------------------------------------------------------------}
- {----------------------------------------------------------------------------}
- {----------------------------------------------------------------------------}
- PROCEDURE TNothingDocument.DoMakeViews(forPrinting: BOOLEAN); OVERRIDE;
-
- Var
- aScroller : TScroller;
- aWindow : TCC_Window;
- aWMGRWindow : WindowPtr;
-
- BEGIN
-
- New (aWindow);
- FailNil (aWindow);
-
- aWMGRWindow := GetNewWindow(1001, nil, Pointer( - 1));
- aWindow.IWindow (self, aWMGRWindow, true, true, true);
-
-
- aScroller := TScroller (DoCreateViews(SELF, NIL, kNothingWindowID));
- aScroller.CreateScrollBars (true, true);
- fNothingView := TNothingView (aScroller.FindSubView ('NOTH'));
-
- aWindow.AddSubView (aScroller);
- aWindow.SetTarget (fNothingView);
- aWindow.fTargetID := 'NOTH';
-
- END;
-
-
- Any help is much appreciated!
-
-
- Tom McCarthy.
- Data Translation, Inc.
-
-
-